-- GENERATED SPELL FOR [Sporewing] --


function spell0_18280(pUnit, Event) --@Energizing Spores,n/a--
pUnit:FullCastSpellOnTarget(35336,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18280', 657, 1)
end

function spell1_18280(pUnit, Event) --@Spore Cloud,n/a--
pUnit:FullCastSpellOnTarget(35394,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18280', 21000, 1)
end

function Sorts_18280(pUnit, Event)
local choix_sorts_18280 = math.random(0, 1)
if choix_sorts_18280 == 0 then
pUnit:RegisterEvent('spell0_18280', 1, 1)
end
if choix_sorts_18280 == 1 then
pUnit:RegisterEvent('spell1_18280', 1, 1)
end
end

function mob18280_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_18280', math.random(1500, 3000), 1)
end

function mob18280_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob18280_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob18280_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(18280, 1, 'mob18280_Action')
RegisterUnitEvent(18280, 2, 'mob18280_Leave')
RegisterUnitEvent(18280, 3, 'mob18280_Kill')
RegisterUnitEvent(18280, 4, 'mob18280_Die')
